package com.example.demo.Service.Impl;

import com.example.demo.Bean.*;
import com.example.demo.Mapper.ProductsMapper;
import com.example.demo.Service.ProductShowService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class ProductShowServiceImpl implements ProductShowService {
    @Autowired
    private ProductsMapper productsMapper;

    @Override
    public List<ProductsShow> getShowProduct(SelectParameter selectParameter) {
        return productsMapper.getShowProduct(selectParameter);
    }

    @Override
    public int getCountProduct(SelectParameter selectParameter) {
        return productsMapper.getCountProduct(selectParameter);
    }

    @Override
    public List<ProductsShow> getShowCategory(SelectParameter selectParameter) {
        return productsMapper.getShowCategory(selectParameter);
    }

    @Override
    public int getCountCategory(SelectParameter selectParameter) {
        return productsMapper.getCountCategory(selectParameter);
    }

    @Override
    public List<ProductsShow> getShowByLike(LikeParameter likeParameter) {
        return productsMapper.getShowByLike(likeParameter);
    }

    @Override
    public List<ProductsShow> getAllShowLike(String title) {
        return productsMapper.getAllShowLike(title);
    }

    @Override
    public Detail getDetailProduct(DetailParameter detailParameter) {
        return productsMapper.getDetailProduct(detailParameter);
    }

    @Override
    public List<Comment> getComment(CommentParameter commentParameter) {
        return productsMapper.getComment(commentParameter);
    }
}
